package com.markerhub.entity;
//实体类创建
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;

/**
 * <p>
 * 
 * </p>
 *
 */

@Data//lombok注解自动getset
//@AllArgsConstructor：使用后添加一个构造函数，该构造函数含有所有已声明字段属性参数
//@NoArgsConstructor：为类提供一个无参的构造方法。
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("m_address")
public class Address implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    private Integer userId;
    @NotBlank(message = "手机号不能为空")
    private String phone;
    @NotBlank(message = "地址不能为空")
    private String address;
    @NotBlank(message = "收件人不能为空")
    private String realname;
    @NotBlank(message = "身份证不能为空")
    private String idcard;


}
